package com.wudizaba.microservicesdemocommon.constant;

/**
 * Created by Administrator on 2017/12/20.
 */
public class MqttConstant {
    // MQTT 服务器地址
    public static final String BROKER = "tcp://broker-cn.emqx.io:1883";
    // TLS/SSL
    // String broker = "ssl://broker.emqx.io:8883";

    // MQTT 服务器用户名
    public static final String USERNAME = "emqx";
    // MQTT 服务器密码
    public static final String PASSWORD = "public";
    // MQTT 客户端 ID
    public static final String SUBSCRIBE_CLIENT_ID = "subscribe_client++";
    public static final String PUBLISH_CLIENT_ID = "publish_client";

    // 主题
    public static final String TOPIC_DETECT_DATA = "mqtt/detect/data";
    public static final String TOPIC_DETECT_DEVICE = "topic/detect/d1";

    // QsS 等级
    public static final Integer QOS_0 = 0;
    public static final Integer QoS_1 = 1;
    public static final Integer QoS_2 = 2;

    // 日志提示
    public static final String SUBSCRIBE_SUCCESS = "mqtt订阅成功";
    public static final String PUBLISH_SUCCESS = "mqtt发布成功";
    public static final String DISCONNECT_SUCCESS = "mqtt断开连接成功";
    public static final String RECEIVE_MESSAGE = "mqtt接收到消息";
    public static final String DELIVERY_SUCCESS = "mqtt消息发送成功";


}
